﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using MethodWorx.Core.DomainModel;

namespace MethodWorx.CMS.Content
{
    public class ContentTemplateRepository : QueryableRepository<ContentTemplate>, IContentTemplateRepository
    {

        public ContentTemplateRepository(IQueryable<ContentTemplate> source)
            : base(source)
        {

        }

        public ContentTemplate FindByName(string name)
        {
            return source.FirstOrDefault(ct => ct.Name == name);
        }

        public override void Delete(ContentTemplate entity)
        {
            throw new NotImplementedException();
        }

        public override void Insert(ContentTemplate entity)
        {
            throw new NotImplementedException();
        }

        public override void Update(ContentTemplate entity)
        {
            throw new NotImplementedException();
        }
    }
}
